<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <style type="text/css">
            body {
                font-family: sans-serif;
            }
            .login
            {
                margin-top:-100px;/*half the box's height*/
                margin-left:-200px;/*half the box's width*/
                height:200px;
                width:360px;
                padding: 0;
                padding-left: 30px;
                border:1px solid #ddd;
                background: #f1f1f1;
                border-radius: 5px;
                position: absolute;
                top: 50%; left: 50%;
                box-shadow: 1px 3px 5px 0px #ccc;

            }
            .login label {
                display: inline-block;
                width: 120px;
            }
            .login input:not([type="submit"]):not([type="checkbox"]) {
                height: 30px;
                width: 200px;
                border: 1px solid #ccc;
                border-radius: 5px;
                box-shadow: 0 0 5px 0px #ccc inset;
            }
            .login input[type="submit"] {
                padding: 5px 8px;
                border: none;
                background: #555;
                color: #fff;
            }
        </style>
    </head>
    <body>
        <div class="login">
            <form name="" action="<?php echo URL_BASE . '/admin/checkLogin' ?>" method="post">
                <?php
                if (isset($_COOKIE['email'])) {
                    ?>
                    <p>
                        <label>Tên đăng nhập:</label>
                        <input type="text" name="txtEmail" value="<?php echo $_COOKIE['email']; ?>" />
                    </p>
                    <p>
                        <label>Mật khẩu:</label>
                        <input type="password" name="txtPass" value="<?php echo $_COOKIE['ad_pass']; ?>" />
                    </p>
                    <?php
                } else {
                    ?>
                    <p>
                        <label>Tên đăng nhập</label>
                        <input type="text" name="txtEmail" />
                    </p>
                    <p>
                        <label>Mật khẩu</label>
                        <input type="password" name="txtPass" />
                    </p>
                    <?php
                }
                ?>
                <p>
                    <label></label>
                    <input type="checkbox" name="chkRemember" value="1" checked /> Nhớ mật khẩu
                </p>
                <p>
                    <label>&nbsp;</label>
                    <input type="submit" name="btnSubmit" value="Đăng nhập" />
                </p>
            </form>
        </div>
    </body>
</html>
